package com.zjt.entity.product;

import com.zjt.entity.BaseEntity;
import com.zjt.entity.IdEntity;

import javax.persistence.Entity;
import javax.persistence.Table;
import java.util.Date;

/**
 * Created with IntelliJ IDEA.
 * User: xueyanbeijing
 * Date: 12-8-24
 * Time: AM6:44
 * To change this template use File | Settings | File Templates.
 */
@Entity
//表名与类名不相同时重新定义表名.
@Table(name="s_security_code")
public class SecurityCode extends BaseEntity{
    private long userId;   //用户id
    private String barCode;  //条形码
    private String securityCode;  //安全码     将来扩展为  安全码验证码接口

    private long  productId;//产品ID

    public long getProductId() {
        return productId;
    }

    public void setProductId(long productId) {
        this.productId = productId;
    }

    public long getUserId() {
        return userId;
    }

    public void setUserId(long userId) {
        this.userId = userId;
    }

    public String getBarCode() {
        return barCode;
    }

    public void setBarCode(String barCode) {
        this.barCode = barCode;
    }

    public String getSecurityCode() {
        return securityCode;
    }

    public void setSecurityCode(String securityCode) {
        this.securityCode = securityCode;
    }

    @Override
    public String toString() {
        return "SecurityCode{" +
                "userId=" + userId +
                ", barCode='" + barCode + '\'' +
                ", securityCode='" + securityCode + '\'' +
                ", productId=" + productId +
                '}';
    }
}
